<template>
  <div
    class="tag-wrapper"
    @click="onClick"
  >
    <div class="tag">{{text}}</div>
  </div>
</template>

<script>
export default {
  props: {
    text: {
      type: String,
      default: ''
    }
  },
  methods: {
    onClick () {
      this.$emit('onClick')
    }
  }
}
</script>

<style lang="scss" scoped>
.tag-wrapper {
  width: 100%;
  box-sizing: border-box;
  background: #f7f7f9;
  border-radius: 32px;
  display: inline-block;
  justify-content: center;
  align-items: center;
  padding: 6px 17px;
  .tag {
    font-size: 17px;
    color: #272e37;
    width: 100%;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }
}
</style>
